<?
$tmppath="../../";
REQUIRE ($tmppath."include/login.php");
REQUIRE ($tmppath.$templates."up.php");
REQUIRE($tmppath."protect/connect_jeu.php");

$query="SELECT rapport_id, rapport_titre, rapport_date, rapport_text FROM sdmrapport WHERE rapport_id=$mess";
$resultat=mysql_query($query);
$tmp=mysql_fetch_array($resultat);


$date=$tmp[2];

//Marquer le message comme vu.
//****************************
$query="UPDATE sdmrapport SET rapport_lu='o' WHERE rapport_id=$mess";

//0 = id 1 = sujet 2 origine 3 =date
$resultat=mysql_query($query);


$tmp[4]=htmlentities($tmp[3]);
$tmp[4]=nl2br($tmp[3]);


?>

<table width="547" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr background="../../images/divers/parch1.gif"> 
    <td colspan="3"><div align="center"><img src="../../images/divers/parch1.gif" width="592" height="30"></div></td>
  </tr>
  <tr> 
    <td width="3%" background="../../images/divers/parch3.gif">&nbsp;</td>
    <td width="92%" background="../../images/divers/parch.jpg">
    <?
    echo "$tmp[1]";
    
    
    ?>

    <br>
      <hr>
      <p> <? echo $tmp[4]; ?> <br>
      </p>
      <hr>
      <p>

    <?
    echo "Message envoyer le $date";


    ?>
      <br>
      </p>
</td>
    <td width="5%" background="../../images/divers/parch4.gif">&nbsp;</td>
  </tr>
  <tr background="../../images/divers/parch2.gif"> 
    <td colspan="3"><img src="../../images/divers/parch2.gif" width="592" height="30"></td>
  </tr>
</table>
<br>
<table width="50%" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr> 
    <td> <div align="center"></div>
      <div align="center"> <? echo"<a href=\"messagerie_test.php?mode=effacerr&message=$tmp[0]&$SID\">Effacer 
        le message</a>" ?></div></td>
  </tr>
</table>
